/*
 * $Id: rex.h,v 1.2 2005-12-16 17:57:23 bacon Exp $
 */

#ifndef _XP_BAS_REX_H_
#define _XP_BAS_REX_H_

#include <xp/types.h>
#include <xp/macros.h>

/*
 * TYPE: xp_rex_t
 *   Defines a regular expression object
 */
typedef struct xp_rex_t xp_rex_t;

struct xp_rex_t
{
	xp_bool_t __dynamic;
};

#ifdef __cplusplus
extern "C" {
#endif

/* 
 * FUNCTION: xp_rex_open
 */
xp_rex_t* xp_rex_open (xp_rex_t* rex);

/* 
 * FUNCTION: xp_rex_close
 */
void xp_rex_close (xp_rex_t*);

/*
 * FUNCTION: xp_rex_match
 */
int xp_rex_match (xp_rex_t* rex, const xp_char_t* str);

/*
 * FUNCTION: xp_rex_matchx
 */
int xp_rex_matchx (xp_rex_t* rex, const xp_char_t* str, xp_size_t len);

#ifdef __cplusplus
}
#endif

#endif
